package com.pi.base.mapper;

import java.util.List;
import java.util.Map;

import com.pi.base.entity.SysMenu;
import com.pi.base.entity.SysRole;

public interface BaseSysRoleMapper {

	/**
	 * 根据roleId查询菜单及父菜单的
	 * @param roleId
	 * @return
	 * @throws Exception
	 */
	public String queryMenuWithParentByRoleIdFunc(Map<String,Object> params) throws Exception;
	
	/**
	 * 查询menu列表
	 * @param params
	 * @return
	 * @throws Exception
	 */
	public List<SysMenu> queryAllMenuByRoleIdAndLevel(Map<String,String> params) throws Exception;
	
	/**
	 * 查询角色的全部按钮权限
	 * @param roleId
	 * @return
	 * @throws Exception
	 */
	public String queryButtonCodeStrsByRoleId(Map<String,Object> params) throws Exception;
	
	/**
	 * 根据节点菜单查询下面的全部菜单
	 * @param map
	 * @return
	 * @throws Exception
	 */
	public List<SysMenu> queryMenuWithSubByID(Map<String,String> map) throws Exception ;
	
	/**
	 * 新增角色并返回角色ID
	 * @param sysRole
	 * @return
	 * @throws Exception
	 */
	public int insertRoleReturnId(Map<String,Object> params)  throws Exception ;
	
	/**
	 * 查询角色的全部菜单
	 * @param roleId
	 * @return
	 * @throws Exception
	 */
	public String queryMenuIdStrsByRoleId(Map<String,Object> params)  throws Exception ;
}
